package com.exce.om2;

/**
 * @Author WaveHi
 * @Date 3/8/2021 上午 11:03
 * @Version 1.0
 * @Contact HJBWaveHi@163.com
 * @Description
 */
public class Boat {

    private String color;//颜色
    private int weight;//重量

    /**
     * 行驶
     */
    public void drive() {

        System.out.println("我可以在水上行驶。");

    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public int getWeight() {
        return weight;
    }

    public void setWeight(int weight) {
        this.weight = weight;
    }

    public Boat() {
    }

    public Boat(String color, int weight) {
        this.color = color;
        this.weight = weight;
    }
}
